#include "lightSensor.h"

void light(){
    int sensor_value = analogRead(lightSen);
    Serial.println(sensor_value);
    
    if (sensor_value < 800)// the point at which the state of LEDs change
    {
         digitalWrite(lightControlPin, HIGH);
    }
    else
    {
         
         digitalWrite(lightControlPin,LOW); //Sets LEDs OFF
    } 
  }


void lightSensorinit(){
     pinMode(lightControlPin, OUTPUT);
     pinMode(lightSen, INPUT);
}
